package com.hdl.design.pattern.engine.strategy.ao;

import java.util.Map;

/**
 * 类名 ReqToAoContext
 * 描述 请求Map转化为AoMap的上下文
 *
 * @author hedonglin
 * @version 1.0
 * @date 2019/9/25 16:19
 */
public class ReqToAoContext {
    /**
     * 请求Map转AoMap的策略
     */
    private AoStrategy aoStrategy;

    public ReqToAoContext(AoStrategy aoStrategy) {
        this.aoStrategy = aoStrategy;
    }

    /**
     * 方法描述: 上下文方法
     * @param reqMap 请求Map
     * @param aoMap AoMap
     * @author hedonglin
     * @date 2019/9/25 16:21
     * @return {@link Map} aoMap
    */
    public Map<String, Object> context(Map<String, Object> reqMap, Map<String, Object> aoMap){
        return aoStrategy.reqMapToAo(reqMap, aoMap);
    }


}
